﻿using System;
using System.Collections.Generic;
using System.Configuration;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Xinchen.SOA.Server
{
    public class ConfigSection : ConfigurationSection
    {
        [ConfigurationProperty("contracts", IsDefaultCollection = false)]
        [ConfigurationCollection(typeof(ContractCollection), AddItemName = "add")]
        public ContractCollection Contracts
        {
            get
            {
                return (ContractCollection)base["contracts"];
            }
        }

        [ConfigurationProperty("applicationId",IsRequired=true)]
        public string ApplicationId
        {
            get
            {
                return (string)base["ApplicationId"];
            }
        }

        [ConfigurationProperty("applicationKey", IsRequired = true)]
        public string ApplicationKey
        {
            get
            {
                return (string)base["applicationKey"];
            }
        }
    }
}
